package org.assertj.ohos.api.content.res;

import ohos.global.configuration.Configuration;
import org.assertj.core.api.AbstractAssert;

/** Assertions for {@link Configuration} instances. */
public class ConfigurationAssert extends AbstractAssert<ConfigurationAssert, Configuration> {
  public ConfigurationAssert(Configuration actual) {
    super(actual, ConfigurationAssert.class);
  }
/* // TODO: wang, not found in ohos
  public ConfigurationAssert hasLayoutDirection(Component.LayoutDirection layoutDirection) {
    isNotNull();
    int actualLayoutDirection = actual.direction;
    //noinspection ResourceType
    assertThat(actualLayoutDirection) //
        .overridingErrorMessage("Expected layout direction to be <%s> but was <%s>.",
            layoutDirectionToString(layoutDirection),
            layoutDirectionToString(actualLayoutDirection)) //
        .isEqualTo(layoutDirection);
    return this;
  }


  public ConfigurationAssert hasMnc(int mnc) {
    isNotNull();
    int actualMnc = actual.mnc;
    assertThat(actualMnc) //
        .overridingErrorMessage("Expected mnc to be <%s> but was <%s>.", mnc, actualMnc) //
        .isEqualTo(mnc);
    return this;
  }

  public ConfigurationAssert hasMncZero() {
    isNotNull();
    int actualMnc = actual.mnc;
    assertThat(actualMnc) //
        .overridingErrorMessage("Expected mnc to be zero but was <%s>.", actualMnc) //
        .isEqualTo(MNC_ZERO);
    return this;
  }
*/

  // TODO a lot!

/* // TODO: wang, not found in ohos
  public static String uiModeTypeToString(@ConfigurationUiModeType int mode) {
    return buildNamedValueString(mode)
        .value(UI_MODE_TYPE_NORMAL, "normal")
        .value(UI_MODE_TYPE_APPLIANCE, "appliance")
        .value(UI_MODE_TYPE_CAR, "car")
        .value(UI_MODE_TYPE_DESK, "desk")
        .value(UI_MODE_TYPE_TELEVISION, "television")
        .value(UI_MODE_TYPE_UNDEFINED, "undefined")
        .value(UI_MODE_TYPE_WATCH, "watch")
        .get();
  }*/
}
